<template>
	<el-drawer title="返工详情" v-model="visible" size="560" destroy-on-close>
		<el-container>
			<el-main>
				<el-table :data="subjectData">
					<el-table-column type="index" width="30" />
					<el-table-column prop="badCode" label="不良代码" width="120" />
					<el-table-column prop="badContent" label="不良内容" width="260" />
					<el-table-column prop="remark" label="备注" />
				</el-table>
			</el-main>
		</el-container>
	</el-drawer>
</template>

<script>
export default {
    data() {
        return {
            visible: false,
            subjectData: [],
        };
    },
    methods: {
        async open(item) {
            const resp = await this.$API.reworkdocline.listByDocId.get(item.id);
            this.subjectData = resp.data;
            this.visible = true;
        }
    }
}
</script>
